.TH strxfrm 3 "" "" ""
.SH SYNOPSIS
strxfrm \- transform string
.SH ANSI_SYNOPSIS
#include <string.h>
.br
size_t strxfrm(char *
.IR s1 ,
const char *
.IR s2 ,
size_t 
.IR n );
.br
.SH TRAD_SYNOPSIS
#include <string.h>
.br
size_t strxfrm(
.IR s1 ,
.IR s2 ,
.IR n );
.br
char *
.IR s1 ;
.br
char *
.IR s2 ;
.br
size_t 
.IR n ;
.br
.SH DESCRIPTION
This function transforms the string pointed to by 
.IR s2 
and
places the resulting string into the array pointed to by
.IR s1 .
The transformation is such that if the 
.BR strcmp 
function is applied to the two transformed strings, it returns
a value greater than, equal to, or less than zero,
correspoinding to the result of a 
.BR strcoll 
function applied
to the same two original strings.

No more than 
.IR n 
characters are placed into the resulting
array pointed to by 
.IR s1 ,
including the terminating null
character. If 
.IR n 
is zero, 
.IR s1 
may be a null pointer. If
copying takes place between objects that overlap, the behavior
is undefined.

With a C locale, this function just copies.
.SH RETURNS
The 
.BR strxfrm 
function returns the length of the transformed string
(not including the terminating null character). If the value returned
is 
.IR n 
or more, the contents of the array pointed to by
.IR s1 
are indeterminate.
.SH PORTABILITY
.BR strxfrm 
is ANSI C.

.BR strxfrm 
requires no supporting OS subroutines.
.SH QUICKREF
strxfrm ansi pure
.SH SOURCE
src/newlib/libc/string/strxfrm.c
